Ext.namespace("Owner");
Owner.Main = function(data) {
		 this.siteId=data;
	   	 this.tabPanel = new Ext.TabPanel({
	   	 	region:'center',
	        activeTab:0,
	        frame:true,
	        autoHeight:true,
	        deferredRender:false, 
			layoutOnTabChange:true
	    });
   	 	if(!Owner.List.instance)
			Owner.List.instance = new Owner.List();
			Owner.List.instance.searchOwner(this.siteId);
		this.tabPanel.add(Owner.List.instance);
		
		if(!Power.List.instance)
			Power.List.instance = new Power.List();
			Power.List.instance.searchOwner(this.siteId);
		this.tabPanel.add(Power.List.instance);
		Owner.Main.superclass.constructor.call(this, {
		    width:670,
		    layout: 'fit',
			closeAction : 'hide',
	        items: [this.tabPanel],
	        listeners:{
			}
		});	
};

Ext.extend(Owner.Main, Ext.Window, {
	
});